A storage apparatus comprises a storage device for storing data and a controller for controlling the storage device, and provides a large capacity data storage space to a host or computer coupled to the storage apparatus.
The storage apparatus can increase I/O processing speed and achieve high fault tolerance with respect to storage device failures by using multiple storage devices (for example HDD (Hard Disk Drives) in a RAID (Redundant Array of Independent (or Inexpensive) Disks) configuration.
The storage apparatus is generally mounted with HDDs as the storage devices, but in recent years, storage devices, which comprise flash memory, for example, SSD (Solid State Drives) are attracting attention as new storage devices for use in place of HDDs. The SSD generally comprises a NAND-type flash memory, and as such, data reads and data writes are carried out in page units.
When a long time has passed since a data was written in the flash memory, or, when the flash memory has gotten worse, bit corruption can occur in the data that has been written in the flash memory (hereinafter, a bit that has undergone bit corruption will be called an “error bit”). Consequently, to maintain the reliability of the data in a general flash memory, a guarantee code (for example, an ECC (Error Correcting Code)) is assigned to the data, and the guarantee code is written to the storage device with the data (Patent Literature 1).